var myChart=echarts.init(document.getElementById("idx1"));//找位置
//配置绘图参数
var option={
    title: {
        text: '徐龙',
    },
    xAxis: {},
    yAxis: {},
    series:{
        type:'scatter',
        data:[[1,1,20],[2,3,39],[5,2,13],[7,6,27]],
        symbolSize: function(x){
            return x[2];
        },
    }

};
//画图
myChart.setOption(option);
// =====================
var myChart2=echarts.init(document.getElementById("idx2"));//找位置
//配置绘图参数
var option2 = {
    title: {
        text: '徐龙',
    },
    xAxis: {
      scale: true
    },
    yAxis: {
      scale: true
    },
    series: [
      {
        type: 'effectScatter',
        symbolSize: 20,
        data:[[1,1,20],[2,3,39],[5,2,13],[7,6,27]],
      },
      {
        type: 'scatter',
        data:[[1,1,20],[2,3,39],[5,2,13],[7,6,27]],
      }
    ]
  };
//画图
myChart2.setOption(option2);
// =====================
function getRandInt(min,max){
    min+(max-min)*Math.random()
    return Math.floor(min+(max-min)*Math.random());
}
var ndata=[];
var x,y,z;
for(var i=0;i<50;i++){
    x=getRandInt(1,100);
    y=getRandInt(1,100);
    z=getRandInt(2,16);
    ndata.push([x,y,z]);
}
var myChart3=echarts.init(document.getElementById("idx3"));//找位置
//配置绘图参数
var option3={
    title: {
        text: '徐龙',
    },
    xAxis: {},
    yAxis: {},
    series:{
        type:'effectScatter',
        data:ndata,
        symbolSize: function(x){
            return x[2];
        },
    }

};
//画图
myChart3.setOption(option3);

function getRandInt(min,max){
    min+(max-min)*Math.random()
    return Math.floor(min+(max-min)*Math.random());
}
var ndata=[];
var x,y,z;
for(var i=0;i<50;i++){
    x=getRandInt(1,100);
    y=getRandInt(1,100);
    z=getRandInt(2,5);
    ndata.push([x,y,z]);
}
var myChart4=echarts.init(document.getElementById("idx4"));//找位置
//配置绘图参数
var option4={
    title: {
        text: '徐龙',
    },
    xAxis: {},
    yAxis: {},
    series:{
        type:'effectScatter',
        data:ndata,
        symbolSize: function(x){
            return x[2];
        },
    }

};
//画图
myChart4.setOption(option4);
setInterval(function(){
    var ndata=[];
var x,y,z;
for(var i=0;i<50;i++){
    x=getRandInt(1,100);
    y=getRandInt(1,100);
    z=getRandInt(2,20);
    ndata.push([x,y,z]);};
    option4.series.data =ndata;
    myChart4.setOption(option4)

},1000);









var myChart5 = echarts.init(document.getElementById("idx5"))
var option5 = {
    series:{
        type:'wordCloud',
        data:[
            {name:'赵',value:100},
            {name:'钱',value:90},
            {name:'孙',value:80},
            {name:'李',value:70},
            {name:'周',value:60},
            {name:'吴',value:50},
            {name:'郑',value:40},
            {name:'王',value:30},
        ],
    },
};
myChart5.setOption(option5);
//------------------------------------------
var myChart6 = echarts.init(document.getElementById("idx6"))
var dataX = [];
for(var i=100;i>0;i--){
    dataX.push({
        name:String(i),
        value:i
    });
}
var option6 = {
    series:{
        type:'wordCloud',
        data:dataX
    },
};
myChart6.setOption(option6);